#-*-coding:utf8-*-
from pyquery import PyQuery as pyq
import urllib

def addPage(url):
  print "addPage: " + str(url)
  page = urllib.urlopen(url)
  html = page.read()
  jq =pyq(html)
  lists = jq('div.h_list div.h_item')
  for l in lists:
      hotalName = jq('img', l).attr('alt')
      address = jq('div.h_info_base p.h_info_b2', l).text()
      price = jq('div.h_info_pri span.h_pri_num', l).text()
      print u'酒店名称：' + hotalName
      print u'酒店地址：' + address
      print u'酒店价格：' + price

addPage("http://hotel.elong.com/search/list_cn_1001.html?aioIndex=-1&aioVal=")